package com.fyt.controller.dictionary.specific;

import com.fyt.controller.utils.Result;
import com.fyt.mapper.AnimalvarietyMapper;
import com.fyt.service.dictionary.specific.AnimalvarietyService;
import io.swagger.annotations.Api;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import java.util.Map;

@Api("畜牧品种")
@RestController
public class AnimalVarietyController {
    @Autowired
    private AnimalvarietyService animalvarietyService;

    @PostMapping("/api/dictionary/animalvariety/add")
    public Result addName(@RequestBody Map<String,String>map){
        return animalvarietyService.addName(map);
    }
    @PutMapping("/api/dictionary/animalvariety/update")
    public Result updateEnable(@RequestBody Map<String,String>map){
        return animalvarietyService.updateEnable(map);
    }
    @GetMapping("/api/dictionary/animalvariety/getList/{id}")
    public Result getList(@PathVariable String id){
        return animalvarietyService.getList(id);
    }

//    @GetMapping("/api/dictionary/animalvariety/getList/{id}")
//    public Result getListByMap(@RequestParam Map<String,String>map){
//        return animalvarietyService.getListByMap(map);
//    }

}
